Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Validate indexes for CONTROL data #188

Merged
merged 3 commits into from
May 28, 2021
Merged

Validate indexes for CONTROL data #188

merged 3 commits into from
May 28, 2021

Conversation

takluyver
Copy link
Member

Previously, we were only checking the indexes for INSTRUMENT data, not CONTROL. I think we may have assumed that CONTROL was unlikely to go wrong. On #187, we found a run where there is a problem - CONTROL data missing, INDEX still records it as though it was there - which extra-data-validate did not pick up.

This extends the same checks we do on INSTRUMENT data to CONTROL, with one difference. We only record the "Index referring to data outside dataset" problem once per source & per file, rather than for every key. When I recorded it for every key, I got a list of some 27000 problems with the run. Once per source should be plenty to point out the problem, and then you can use h5glance to find more detail if necessary.

Checking run directory: /gpfs/exfel/exp/SPB/201901/p002316/raw/r0174
Progress: 207/207 [##################################################]
84 problems in 7 files (last: RAW-R0174-DA02-S00002.h5)
Validation failed! 84 problems:

Index referring to data (11) outside dataset (0)
  dataset: CONTROL/SPB_IRU_AGIPD1M1/CTRL/MC1/module2/dBoardTemperature2/timestamp
  file: /gpfs/exfel/exp/SPB/201901/p002316/raw/r0174/RAW-R0174-DA02-S00006.h5

Index referring to data (11) outside dataset (0)
  dataset: CONTROL/SPB_IRU_AGIPD1M/TSENS/Q2_T_BLOCK/force/timestamp
  file: /gpfs/exfel/exp/SPB/201901/p002316/raw/r0174/RAW-R0174-DA02-S00006.h5

...

@takluyver takluyver added the enhancement New feature or request label May 27, 2021
@takluyver takluyver requested a review from tmichela May 27, 2021 16:05
@tmichela
Copy link
Member

I wonder if we should try to summarize similar problems to avoid returning N times the same output with just a different source name, ex:

Index referring to data (11) outside dataset (0) for 82 sources, example:
  dataset: CONTROL/SPB_IRU_AGIPD1M1/CTRL/MC1/module2/dBoardTemperature2/timestamp
  file: /gpfs/exfel/exp/SPB/201901/p002316/raw/r0174/RAW-R0174-DA02-S00006.h5

and add a verbose argument.

But that's a different issue.

LGTM

@takluyver takluyver added this to the 1.7 milestone May 28, 2021
@takluyver takluyver merged commit 4e0cfea into master May 28, 2021
@takluyver takluyver deleted the validate-control-index branch May 28, 2021 09:35
@takluyver
Copy link
Member Author

Thanks - I've opened #190 for summarising the issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants